<?php
namespace catchAdmin\basics\request;

use catchAdmin\basics\model\Provider;
use catcher\base\CatchRequest;

class ProviderCreateRequest extends CatchRequest
{

    protected function rules(): array
    {
        // TODO: Implement rules() method.
        return [
            'account_code|账户代码' => 'require|max:16|alphaNum|unique:'.Provider::class,
            'account_name|账户名称' => 'require|unique:'.Provider::class,
        ];
    }

    protected function message()
    {
        // TODO: Implement message() method.
        return [
            'account_code.max'=>"账户代码最长16位字符"
        ];
    }
}